/**
 * 
 */
package com.feib.soeasy.job.util;

/**
 * @author Jimmy Liu
 *
 */
public class AutoUploadCarLoanFileMailContent extends MailContentTemplate
{
	private String otherContent = null;
	private String exceptionMessage = null;

	public AutoUploadCarLoanFileMailContent(String messageTile,
			String[] paragraphs, String htmlMailFolder) {
		super(messageTile, paragraphs, htmlMailFolder);
	}

	@Override
	protected StringBuffer getOtherContent(StringBuffer html) {

		if (null != otherContent)
		{
			html.append("            <p>通知訊息</p>");
			html.append("            <table border=\"1\" style=\"width: 100%; \">");
			html.append("                <tr style=\"background: #f4e3e3;\">");
			html.append("                   <th>通知訊息</th>");	        
			html.append("                </tr>");
			html.append("                <tr>");            
			html.append("                   <td>").append(otherContent).append("</td>");
			html.append("                </tr>");
			html.append("            </table>");
		}

		if (null != exceptionMessage)
		{
			html.append("            <p>錯誤訊息</p>");
			html.append("            <table border=\"1\" style=\"width: 100%; \">");
			html.append("                <tr style=\"background: #f4e3e3;\">");
			html.append("                   <th>系統訊息</th>");	        
			html.append("                </tr>");
			html.append("                <tr>");            
			html.append("                   <td>").append(exceptionMessage).append("</td>");
			html.append("                </tr>");
			html.append("            </table>");
		}

		return super.getOtherContent(html);
	}

	public String getOtherContent() {
		return otherContent;
	}

	public void setOtherContent(String otherContent) {
		this.otherContent = otherContent;
	}

	public String getExceptionMessage() {
		return exceptionMessage;
	}

	public void setExceptionMessage(String exceptionMessage) {
		this.exceptionMessage = exceptionMessage;
	}

}
